<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>SPAM3-UK Ford汽车信息测试页面 v1.4.0</title>
    
    <!-- 样式文件 -->
    <link rel="stylesheet" href="/web/assets/css/styles.css">
    
    <!-- 预加载关键资源 -->
    <link rel="preload" href="/web/assets/js/main.js" as="script">
    <link rel="preload" href="/web/assets/js/trim.js" as="script">
</head>
<body>
    <div class="container">
        <!-- 页面标题 -->
        <h1>🚗 SPAM3-UK Ford汽车信息测试页面</h1>
        <div class="text-center mb-20">
            <span class="page-type-indicator page-type-modern">v1.4.0</span>
            <span class="page-type-indicator page-type-performance">多页面适配</span>
            <span class="page-type-indicator page-type-classic">Issue #013已修复</span>
        </div>

        <!-- 操作按钮区域 -->
        <div class="text-center mb-20">
            <button id="refreshData" class="btn btn-primary">🔄 刷新数据</button>
            <button id="clearFilters" class="btn btn-secondary">🗑️ 清除筛选</button>
        </div>

        <!-- 统计信息卡片 -->
        <div class="stats">
            <div class="stat-card">
                <div class="stat-number" id="totalVehicles">0</div>
                <div class="stat-label">总车辆数</div>
            </div>
            <div class="stat-card">
                <div class="stat-number" id="avgPrice">£0</div>
                <div class="stat-label">平均价格</div>
            </div>
            <div class="stat-card">
                <div class="stat-number" id="uniqueModels">0</div>
                <div class="stat-label">车型数量</div>
            </div>
            <div class="stat-card">
                <div class="stat-number" id="fuelTypeStats">N/A</div>
                <div class="stat-label">主要燃料类型</div>
            </div>
        </div>

        <!-- 筛选器区域 -->
        <div class="filters">
            <h3>🔍 筛选条件</h3>
            
            <div class="filter-row">
                <div class="filter-group">
                    <label for="makeFilter">制造商:</label>
                    <select id="makeFilter">
                        <option value="">全部制造商</option>
                    </select>
                </div>
                
                <div class="filter-group">
                    <label for="modelFilter">车型:</label>
                    <select id="modelFilter">
                        <option value="">全部车型</option>
                    </select>
                </div>
                
                <div class="filter-group">
                    <label for="fuelTypeFilter">燃料类型:</label>
                    <select id="fuelTypeFilter">
                        <option value="">全部燃料类型</option>
                    </select>
                </div>
                
                <div class="filter-group">
                    <label for="bodyStyleFilter">车身类型:</label>
                    <select id="bodyStyleFilter">
                        <option value="">全部车身类型</option>
                    </select>
                </div>
            </div>
            
            <div class="filter-row">
                <div class="filter-group">
                    <label for="minPrice">最低价格 (£):</label>
                    <input type="number" id="minPrice" placeholder="例如: 20000" min="0">
                </div>
                
                <div class="filter-group">
                    <label for="maxPrice">最高价格 (£):</label>
                    <input type="number" id="maxPrice" placeholder="例如: 50000" min="0">
                </div>
            </div>
        </div>

        <!-- 车辆展示区域 -->
        <div class="vehicle-grid" id="vehicleGrid">
            <div class="loading text-center" style="grid-column: 1/-1;">正在加载车辆数据...</div>
        </div>

        <!-- Trim配置模态框 -->
        <div id="trimModal" class="trim-modal">
            <div class="trim-modal-content">
                <button class="close-modal" onclick="closeTrimModal()" title="关闭">&times;</button>
                <h2 id="trimModalTitle">车型配置信息</h2>
                <div id="trimContent">加载中...</div>
            </div>
        </div>
    </div>

    <!-- 脚本文件 -->
    <script src="/web/assets/js/main.js"></script>
    <script src="/web/assets/js/trim.js"></script>
    
    <!-- 页面性能监控 -->
    <script>
        // 简单的性能监控
        window.addEventListener('load', function() {
            console.log('📊 页面加载完成:', {
                loadTime: performance.now(),
                resources: performance.getEntriesByType('resource').length,
                timestamp: new Date().toISOString()
            });
        });
    </script>
</body>
</html>
